home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part1 / 7383 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.3 KB

  1. Path: news.umbc.edu!not-for-mail
  2. From: schlein@umbc.edu (Jonas J. Schlein)
  3. Newsgroups: comp.lang.c
  4. Subject: Re: sqrt() cheesy question
  5. Date: 25 Feb 1996 19:34:43 -0500
  6. Organization: University of Maryland Baltimore County
  7. Message-ID: <4gqv73$ie8@umbc9.umbc.edu>
  8. References: <4gjmmt$lt7@hopi.dtcc.edu>
  9. NNTP-Posting-Host: umbc9.umbc.edu
  10. NNTP-Posting-User: schlein
  11.  
  12. Rob Wiltbank <w4582@hopi.dtcc.edu> wrote:
  13. |> Howdy all.  I'm in a bind.
  14. |> 
  15. |> I'm in a beggining C course at school, and I'm about 2 weeks ahead of the 
  16. |> class so I'm doing projects that the class hasn't even considered going 
  17. |> over yet.  I'm still on the very newbie side of it all.
  18. |> 
  19. |> Could someone post the function definition of the sqrt() function found 
  20. |> in math.h?
  21.  
  22. First of all why do you need to know unless your professor wants you
  23. to implement your own version. Secondly, please correct me if I'm wrong,
  24. but does the standard actually give an explicit formula on how a sqrt()
  25. must be written? I'd think it would define behavior and allow the
  26. implementor whatever freedom they need.
  27.  
  28. Using some kind of fixed point approximation would work as would Newton's
  29. method. However, these are more number theory than a beginning C class.
  30. -- 
  31. "If it wasn't for C, we would be using BASI, PASAL, and OBOL."
  32.  
  33. Jonas J. Schlein  (schlein@gl.umbc.edu)
  34.